import Vue from 'vue'
import VueRouter from 'vue-router'
import My from '@/views/my.vue'
import Home from '@/views/home.vue'
import Class from '@/views/class.vue'
import Order from '@/views/order.vue'
Vue.use(VueRouter)
//路由配置
const routes = [
  {
    path: '/',
    redirect: '/home'
  },
  {
    path: '/my',
    component: My,
  },
  {
    path: '/home',
    component: Home,
  },
  {
    path: '/class',
    component: Class,
  },
  {
    path: '/order',
    component: Order,
  },
]

const router = new VueRouter({
  routes,
})

export default router
